package com.minimalist.basic.entity.po.table;

import com.mybatisflex.core.query.QueryColumn;
import com.mybatisflex.core.table.TableDef;

// Auto generate by mybatis-flex, do not modify it.
public class MTenantPackagePermTableDef extends TableDef {

    /**
     * 租户套餐与权限关联表 实体类。

 @author 小太阳
 @since 2024-10-18
     */
    public static final MTenantPackagePermTableDef MTENANT_PACKAGE_PERM = new MTenantPackagePermTableDef();

    /**
     * 权限ID
     */
    public final QueryColumn PERM_ID = new QueryColumn(this, "perm_id");

    /**
     * 租户套餐ID
     */
    public final QueryColumn PACKAGE_ID = new QueryColumn(this, "package_id");

    /**
     * 所有字段。
     */
    public final QueryColumn ALL_COLUMNS = new QueryColumn(this, "*");

    /**
     * 默认字段，不包含逻辑删除或者 large 等字段。
     */
    public final QueryColumn[] DEFAULT_COLUMNS = new QueryColumn[]{PERM_ID, PACKAGE_ID};

    public MTenantPackagePermTableDef() {
        super("", "m_tenant_package_perm");
    }

    private MTenantPackagePermTableDef(String schema, String name, String alisa) {
        super(schema, name, alisa);
    }

    @Override
    public MTenantPackagePermTableDef as(String alias) {
        String key = getNameWithSchema() + "." + alias;
        return getCache(key, k -> new MTenantPackagePermTableDef("", "m_tenant_package_perm", alias));
    }

}
